minecraftbedrockfandomcom-20200215-history
Commands/List of Commands
Given below is a detailed list of all Commands in . List of Commands ability Sets a player's ability. /ability abilities Legal values for abilities are: * mute - Permits or denies player's chat options. * worldbuilder - Permit or denies player's ability to place blocks. * mayfly - Permits or denies player's ability to independently fly. This command requires Education Edition features enabled. alwaysday Locks and unlocks the day-night cycle. /alwaysday Sets dodaylightcycle to false, and sets to 5000. This is the same as the Always Day slider in the Game Settings. The command can also be given as daylock. clear Clears the Player's inventory. /clear * player name or target selector. Defaults to the player executing the command. * valid item name. Defaults to all items in the player's inventory. * if specified, only clears items with this data value. * maximum number of items to clear. clone Copies blocks from one place to another. /clone maskMode cloneMode tileName Clones blocks from the cube defined by begin and end into the destination. The maskMode defines how to handle destination blocks, and cloneMode defines handling of source. If maskMode is filtering, the tileName specifies the block to filter on. Legal values for maskMode are: * filtered – Only blocks matching tileName is copied. * masked – Only non-air blocks are copied. * replace – All blocks are copied as-is. This is the default. Legal values for cloneMode are: * force – Force moving of blocks even if regions overlap. * move – Move only non-air blocks, and replace them with air-blocks. If filtering is done, this only applies to the filtered blocks. * normal – Do not force or move blocks from source region. This is the default. See also and commands. connect Connects to a server in-game. /connect *''Note'': URi is as the code appears in the chat. It is unknown if this is a bug. deop Revokes operator status for one or more players. /deop See also , for giving this status. difficulty Changes the difficulty mode. /difficulty int Values for int are: '0' for peaceful; '1' for easy; '2' for normal; '3' for hard; effect Gives or removes a status effect from a player. /effect int int bool enchant Enchant player(s) held item. /enchant int /enchant int Enchant the item the targeted player(s) are holding, with the name (or numbered) enchantment at a given level. Maximum level for a given encha ntment can't be bypassed. execute Executes a command which can be linked to a target or a condition related to another block, as tested in the command. /execute /execute /execute The command in all examples can be any command (including the execute command it self), and are relative to the targeted player(s)/entities. In the latter two examples, the tile notation is used relative to the position of the origin target. The last variant, with the detect string equal to "detect", the command is only executed if the condition, as if it was given to testforblock, is matched. fill Fills a region with a given block /fill tileData:int oldBlockHandling Fills the entire cube defined by from and to with the block named tileName (optionally specifying a tileData value). The oldBlockHandling defines how to handle existing blocks in the region. Legal values for oldBlockHandling are: * destroy – Replace all blocks, drops blocks and contents as if mined with unenchanted diamond pickaxe or shovel. * hollow – Replace only the blocks on the outer edge of the region. Drops all inner blocks as if they were mined, and replaced them with air blocks. * keep – Only replace the air blocks in the fill region with the specified block. * outline – Only replace the outer edge of region with specified block. Leave all inner blocks as they were. * replace – Replace all blocks, with no dropping of current blocks. This is the default. See also and commands. function Runs commands found in the corresponding function file. /function /function gamemode Changes gamemode for a player. /gamemode target /gamemode target Using 'c', 'creative', 's', 'survival', 'a', 'adventure', '0', '1', or '2', the gamemode for the targeted player can change. gamerule Sets or queries a game rule value. /gamerule /gamerule Used to change of game mechanic specified by rule. All rules except keepinventory are set False by default. give Give a targeted player(s) item(s). /give int int json Adds items to the targeted player(s) inventory. Multiple items of the same type can be given by specifying an amount, and some characteristics of the item can be changed by providing the optional data argument. You can also add CanPlaceOn and CanDestroy data tags to items through this command. help Displays help related to commands. /help Lists help related to a specific command. In 0.16.0 this text is rather short (or missing). /help int Typing /help optionally followed by a number gives a list of commands. With a number, like 3, it shows the third help page. immutableworld Sets the immutable state of a world. /Immutableworld Sets ability to place blocks for every player in a world. This command requires Education Edition features enabled. kill Kills (or removes) a player or an entity. /kill target Without argument kills the Player itself. Using a player's name would kill that player, and /kill @etype=creeper would remove all creepers in loaded chunks. See to spawn entities. list Lists all online players of the current game, and maximum players allowed. /list locate Locates the nearest selected structure. /locate The command only gives the coordinates of the nearest structure, the Player must teleport/travel to it themselves. me Displays custom message in chat /me Displays custom chat message starting with player's name, but without the player's name in square brackets. mixer Mixer interactivity control /mixer /mixer /mixer Used in conjunction with Microsoft's (formerly Beams's) Mixer app for livestreaming Minecraft sessions. mobevent Controls what mob events are allowed to run /mobevent Legal values for event are: * events_enabled - Enables or disables all events. * minecraft:pillager_patrols_event - Enables or disables pillager patrols from spawning. * minecraft:wandering_trader_event - Enables or disables wandering trader from spawning. op Gives operator status to one or several players /op See , which revokes this status. particle Creates a particle emitter. /particle playsound Plays a built-in sound. /playsound reload Reloads all function files from all behavior packs. /reload replaceitem Replaces inventory items. /replaceitem int int /replaceitem int int The only valid slotType for block is slot.container. Valid block containers are chests, furnaces, dispensers, droppers, hoppers, and brewing stands. The slotId parameter is zero-based. For example, the 36 slots of the player inventory are numbered 0 to 35. say Says something to all players. /say See also for addressing specific player(s). scoreboard Tracks and display scores for various objectives. /scoreboard objectives add dummy string /scoreboard objectives removed /scoreboard objectives list /scoreboard objectives setdisplay string descending /scoreboard objectives setdisplay belowname string /scoreboard players list target /scoreboard players reset objective:string /scoreboard players test wildcard int /scoreboard players random < max: int> /scoreboard players /scoreboard players operations setmaxplayers Sets maximum number of players for current game session. The max amount of players to 30. /setmaxplayers setblock Changes a single block at a given position. /setblock int oldBlockHandling Replaces the block according to the following values of oldBlockHandling: * destroy – Destroys the original block as if done by The Player, before placing the new block * keep – Only replaces air blocks with the new block * replace – Replaces without regards of old block. No dropping of block or content. This is the default See also and commands. setworldspawn Sets the world spawn /setworldspawn x y z Sets the worlds spawn point to given position. If position is not given, it defaults to the given players current position. After succesfully setting the spawn point, the Compass now points to this point. spawnpoint Sets spawn point for targeted player(s) /spawnpoint target x y z Sets the spawn point of a player to the given position. If neither it is given default to current player and current position. Does not affect the compass. spreadplayers Teleports entities to random locations within a radius /spreadplayers stopsound Stops a currently playing sound. /stopsound sound:string summon Creates an entity at any given position. /summon Spawns the named entity at your given position. I.e. /summon mushroomcow ~ ~ ~. Note that position must be specified. See for removing entities. tag Manages tags stored in entities. /tag add|remove /tag list Changes attributes of an entity to achieve custom effects. Can be used to add abilities or remove designed limitations from a single mob. tell Sends a private message to one or more players. /tell Only targeted player(s) will receive the message. The command can be abbreviated as msg or /w. See also if the message is for everyone. tellraw Sends a JSON message to players /tellraw Used to send messages to player with colorful font effects. testfor Tests for existence of an entity /testfor When used with a target selector specifying coordinates, can be used as motion sensor. testforblock Tests whether a block is in a given location /testforblock int Checks whether the given position has the given block. Reports back through texts in the chat window. testforblocks /testforblocks mode The begin and end arguments specifies the source regions which are matched against a equally sized region starting at destination. Legal values for mode are: * all – Each and every block must match to be part of the match total. This is default. * masked – Air blocks in the source region are ignored in the destination. A succesful match will list number of matching blocks. The region to match might overlap, but it must not be too large. tickingarea Adds areas that update without any Players in them. There can be a maximum of 8 in a world. The maximum area that can be made is 8x8 chunks. /tickingarea add string /tickingarea add circle string /tickingarea remove /tickingarea remove /tickingarea remove_all /tickingarea list all-dimensions time Changes or queries the world's game time. /time add /time query /time set /time set A full day in Minecraft equals 24000 ticks, approx 20 minutes in real time. A day starts at 1000, and night starts at 13000. When querying day refers to whole days, daytime refers to gameticks of current day, and gametime refers to total amount of gameticks since current game started. title Display a message to the players device above the player. /title Does not appear in chat. Special effect similar to a movie title. titleraw Displays screen titles with JSON messages. /titleraw title|subtitle|actionbar Does not appear in chat. Special effect similar to a movie title with colorful font effects. toggledownfall Changed whether there is downfall or not. /toggledownfall If it rains or snows, it'll stop doing so, and vice versa. tp Teleports an entity to a given coordinate. /tp /tp int int /tp /tp int int Teleports either the Player, or a given victim player to the specified destination. Additionally rotates the Player. This command has the interesting side effect of displaying the target coordinates, so that doing a /tp ~ ~ ~ will actually tell the current coordinates of the Player. The command can also be spelled out as /teleport. videostream Attempts to connect to the websocket server to send a video stream. /videostream videostreamaction Performs a videostream related action. /videostreamaction none|close weather Sets the current weather for a given duration. /weather int Sets the weather type to either clear, rain or thunder. Rain becomes snow in a cold biome. Duration, if not set, is random between 6000 and 13000 gameticks. worldbuilder Toggle World Builder staus of a caller. /worldbuilder Allows an individual player the option to toggle the player's own ability to place blocks. This command requires Education Edition features enabled. wsserver Connects to an automation server (developer use only). /wsserver Unknown usage, reportedly used by developers only. Connects to a websocket server using an unknown protocol. xp Adds experience to the targeted player. /xp /xp L In the first variants it adds the amount of experience to the targeted player. If the player adds the L after the amount, it adds levels instead of only experience points. Category:Technical